package com.pq.enums;

public enum CommonCode implements Code{
    SYSTEM_ERROR("-1", "系统异常，请稍后再试"),
    SUCCESS("200", "成功"),
    PARAM_ERROR("400", "请求参数缺失"),
    PARAM_INCORRECT("402", "参数错误"),
    REQUEST_ERROR("408", "请求方式错误"),
    FAILURE("500", "请求失败");

    /**
     * 业务码
     */
    private String code;

    /**
     * 提示
     */
    private String message;

    CommonCode(String code, String message) {
        this.code = code;
        this.message = message;
    }

    @Override
    public String getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
